package com.lelefly.base.po;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import static javax.persistence.GenerationType.IDENTITY;
import javax.persistence.Id;
import javax.persistence.Table;

/**
 * FarmlandAccess entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "farmland_access", catalog = "lelefly")
public class FarmlandAccess implements java.io.Serializable {

	// Fields

	private Integer id;
	private String farmlandid;
	private String usernm;
	private String accessTime;
	private Integer isAgreed;

	// Constructors

	/** default constructor */
	public FarmlandAccess() {
	}

	/** minimal constructor */
	public FarmlandAccess(String farmlandid, String usernm, String accessTime) {
		this.farmlandid = farmlandid;
		this.usernm = usernm;
		this.accessTime = accessTime;
	}

	/** full constructor */
	public FarmlandAccess(String farmlandid, String usernm, String accessTime,
			Integer isAgreed) {
		this.farmlandid = farmlandid;
		this.usernm = usernm;
		this.accessTime = accessTime;
		this.isAgreed = isAgreed;
	}

	// Property accessors
	@Id
	@GeneratedValue(strategy = IDENTITY)
	@Column(name = "id", unique = true, nullable = false)
	public Integer getId() {
		return this.id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	@Column(name = "farmlandid", nullable = false, length = 40)
	public String getFarmlandid() {
		return this.farmlandid;
	}

	public void setFarmlandid(String farmlandid) {
		this.farmlandid = farmlandid;
	}

	@Column(name = "usernm", nullable = false, length = 40)
	public String getUsernm() {
		return this.usernm;
	}

	public void setUsernm(String usernm) {
		this.usernm = usernm;
	}

	@Column(name = "access_time", nullable = false, length = 20)
	public String getAccessTime() {
		return this.accessTime;
	}

	public void setAccessTime(String accessTime) {
		this.accessTime = accessTime;
	}

	@Column(name = "isAgreed")
	public Integer getIsAgreed() {
		return this.isAgreed;
	}

	public void setIsAgreed(Integer isAgreed) {
		this.isAgreed = isAgreed;
	}

}